<@s.url var="namespace" value="/module/category" />

<div class="page-header">
	<h1>List of Category</h1>
</div>
<div class="row">
	<div class="span12">
		<form class="well form-inline" action="${namespace}" method="get">
			<input type="text" name="category.name" class="span6" placeholder="Name..." value="${category.name!}" />
			<button class="btn btn-primary">
				&nbsp;<i class="icon-search icon-white"></i>&nbsp;
			</button>
		</form>
	</div>
</div>
<div class="row">
	<div class="span12">
		<table class="table table-striped table-bordered table-condensed">
			<thead>
				<tr>
					<th>Name</th>
					<th>Description</th>
					<th>Action</th>
				</tr>
			</thead>
			<tbody>
				<#list model.entityList! as c>
				<tr>
					<td>${c.name!}</td>
					<td>${c.description!}</td>
					<td>
						<a class="btn" title="Edit" href="${namespace}/edit/${c.id!}"><i class="icon-edit"></i> Edit</a>
					</td>
				</tr>
				</#list>
				<tr>
					<td colspan="3">
						<a href="<@s.url value="${namespace}/add" />" class="btn btn-primary">New Category</a>
						<div class="btn-group pull-right">
							<#if model.totalPage??>
							<#list 1..model.totalPage as t>
							<a class="btn" href="${namespace}?page=${t}">${t}</a>
							</#list>
							</#if>
						</div>
					</td>
				</tr>
			</tbody>
		</table>
	</div>
</div>